﻿<%@ Assembly Name="$SharePoint.Project.AssemblyFullName$" %>
<%@ Assembly Name="Microsoft.Web.CommandUI, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %> 
<%@ Register Tagprefix="SharePoint" Namespace="Microsoft.SharePoint.WebControls" Assembly="Microsoft.SharePoint, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %> 
<%@ Register Tagprefix="Utilities" Namespace="Microsoft.SharePoint.Utilities" Assembly="Microsoft.SharePoint, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>
<%@ Register Tagprefix="asp" Namespace="System.Web.UI" Assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" %>
<%@ Import Namespace="Microsoft.SharePoint" %> 
<%@ Register Tagprefix="WebPartPages" Namespace="Microsoft.SharePoint.WebPartPages" Assembly="Microsoft.SharePoint, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="AccuseUserControl.ascx.cs" Inherits="JM.JCY.SharePointComponent.LawArchives.Accuse.AccuseUserControl" %>
<%@ Register Src="../LawCaseLeftMenu/LawCaseLeftMenuUserControl.ascx" TagName="LeftMenuUserControl" TagPrefix="uc1" %>
<script type="text/javascript">
    $(document).ready(function () {
        if ($("#<%=hfIsManager.ClientID %>").val() == "Y") {
            $("#trPerson").hide();
        }
    });

    function RedirectToAccuseDetails(sender, N_BH) {

        sender.href = "AccuseDetails.aspx?N_BH=" + N_BH;
    }
    </script>
<div>
    <table class="main">
        <tr>
            <td valign="top" width="25%" runat="server" id="tdLeftMenu">
                <uc1:LeftMenuUserControl ID="LeftMenuUserControl1" runat="server" />
            </td>
         <td valign="top" width="75%" runat="server" id="tdContent">
              
                <table class="content" width="98%">
                    <tr>
                        <td style="padding: 5px;">
                            <table width="100%" class="title">
                                <tr>
                                    <td width="60%">
                                        <h1 class="title">
                                            控告申诉案件</h1>
                                    </td>
                                 
                                </tr>
                            </table>
                        </td>
                    </tr>
                    <tr>
                        <td>
                            <table width="100%" class="form">
                                <tr id="trPerson">
                                    <td width="26%">
                                        <b>受理人</b>
                                    </td>
                                    <td width="1%">
                                        :
                                    </td>
                                    <td width="73%">
                                       <asp:TextBox ID="txtCBR" runat="server" Width="330"></asp:TextBox>
                                    </td>
                                </tr>
                                <tr id="tr1">
                                    <td width="26%">
                                        <b>受理日期</b>
                                    </td>
                                    <td width="1%">
                                        :
                                    </td>
                                    <td width="165">
                                        <div style="position: relative; z-index: 99; width: 50%; left: -7px; top: -5px">
                                            <SharePoint:DateTimeControl ID="StartDate" LocaleId="2052" runat="server" CalendarImageUrl="/_layouts/JM.JCY.Resource/images/calendar.jpg"
                                                CssClassTextBox="ms-input txtClassForCalender validFeild eventDatePre" DateOnly="True"
                                                TimeOnly="False" />
                                        </div>
                                        <span class="ms-formvalidation" id="controltoStartDate" style="display: inline; vertical-align: text-top;
                                            color: red;"></span>
                                   
                                        <div style="position: relative; z-index: 98; width: 65%; left: -7px; top: -5px">
                                            <SharePoint:DateTimeControl ID="EndDate" LocaleId="2052" runat="server" CalendarImageUrl="/_layouts/JM.JCY.Resource/images/calendar.jpg"
                                                CssClassTextBox="ms-input txtClassForCalender validFeild eventDatePre" DateOnly="True"
                                                TimeOnly="False" />
                                        </div>
                                        <span class="ms-formvalidation" id="controltoEndDate" style="display: inline; color: red;">
                                        </span>
                                    </td>
                                </tr>
                            </table>
                        </td>
                    </tr>
                    <tr>
                        <td align="right">
                            <asp:ImageButton ID="imgSearch" runat="server" ImageUrl="~/_layouts/JM.JCY.Resource/images/search.png"  onclick="imgSearch_Click"/>
                            <asp:ImageButton ID="imgReset" runat="server" ImageUrl="~/_layouts/JM.JCY.Resource/images/reset.png" Visible="false" />
                            <%--<asp:ImageButton ID="imgCancel" runat="server" ImageUrl="~/_layouts/JM.JCY.Resource/images/cancel.png" />--%>
                        </td>
                    </tr>
                
                       <tr>
                    <td>
                        <br />
                    <hr id="hr1" />
                    <br />
                    <span id="spResult" class="NoRecordMsg">No category found</span>
                  <table width="100%" class="title">
                        <tr>
                            <td align="right">
                                <div class="pagination" id="divPage1" style="display: none;">
                                    <asp:LinkButton ID="lbFirst" runat="server" Text="<< First |" OnClientClick="turnPage(1);return false;"></asp:LinkButton>
                                    <asp:LinkButton ID="lbPrev" runat="server" Text="< Previous |" OnClientClick='turnPagePrev();return false;'></asp:LinkButton>
                                    <span id="spPager1" runat="server"></span>
                                    <asp:LinkButton ID="lbNext" runat="server" Text="| Next >" OnClientClick='turnPageNext();return false;'></asp:LinkButton>
                                    <asp:LinkButton ID="lbLast" runat="server" Text="| Last >>" OnClientClick='turnPageLast();return false;'></asp:LinkButton>
                                    <input id="currIndex" type="text" value="1" style="display: none;" />
                                    <input id="lastIndex" type="text" style="display: none;" />
                                    <input id="currLinkToSet" type="text" value="1" style="display: none;" />
                                </div>
                            </td>
                        </tr>
                    </table>
                    <table width="100%" border="0" cellpadding="0" cellspacing="10">
                      <tr>
                            <td>
                                <asp:Label ID="NoRecord" runat="server" ForeColor="#CC3300" Text="没有在系统中找到相关的案件！"
                                    Visible="false"></asp:Label>
                            </td>
                        </tr>
                        <tr>
                            <td>
                                <div id="content">
                                    <asp:GridView ID="gvKS" runat="server" AutoGenerateColumns="False" BorderWidth="0px"
                                        GridLines="Horizontal" AllowSorting="True" CssClass="list" Width="100%" 
                                        EnableModelValidation="True" PageSize="20" AllowPaging="true" 
                                        onpageindexchanging="gvKS_PageIndexChanging">
                                        <Columns>
                                         <asp:TemplateField HeaderText="编号" HeaderStyle-Width="15%">
                                                <ItemTemplate>
                                                    <asp:LinkButton ID="id" runat="server" Text='<%# Eval("N_BH") %>' OnClientClick='<%# String.Format("RedirectToAccuseDetails({0},{1})","this",Eval("N_BH")) %>'>
                                                    </asp:LinkButton>
                                                </ItemTemplate>

<HeaderStyle Width="15%"></HeaderStyle>
                                            </asp:TemplateField>
                                            <asp:BoundField DataField="C_AH" HeaderText="案号" HeaderStyle-Width="15%" >
                                            <HeaderStyle Width="25%"></HeaderStyle>
                                            </asp:BoundField>
                                            
                                            <asp:BoundField DataField="D_SARQ" HeaderText="受理日期" HeaderStyle-Width="15%" DataFormatString="{0:yyyy-MM-dd}">
                                                <HeaderStyle Width="15%"></HeaderStyle>
                                            </asp:BoundField>
                                            <asp:BoundField DataField="C_XM" HeaderText="受理人" HeaderStyle-Width="15%" >
                                                <HeaderStyle Width="15%"></HeaderStyle>
                                            </asp:BoundField>
                                           
                                        </Columns>
                                         <PagerSettings FirstPageText="第一页" LastPageText="最后一页" 
                                            Mode="NumericFirstLast" />
                                    </asp:GridView>
                                </div>
                            </td>
                        </tr>
                    </table>
                    <table width="100%" class="title">
                        <tr>
                            <td align="right">
                                <div class="pagination" id="divPage2" style="display: none;">
                                    <asp:LinkButton ID="lbFirst1" runat="server" Text="<< First |" OnClientClick="turnPage(1);return false;"></asp:LinkButton>
                                    <asp:LinkButton ID="lbPrev1" runat="server" Text="< Previous |" OnClientClick='turnPagePrev();return false;'></asp:LinkButton>
                                    <span id="spPager2" runat="server"></span>
                                    <asp:LinkButton ID="lbNext1" runat="server" Text="| Next >" OnClientClick='turnPageNext();return false;'></asp:LinkButton>
                                    <asp:LinkButton ID="lbLast1" runat="server" Text="| Last >>" OnClientClick='turnPageLast();return false;'></asp:LinkButton>
                                </div>
                            </td>
                        </tr>
                    </table>
                    </td>
                    </tr>
                </table>
            </td>
        </tr>
    </table>
</div>

<asp:HiddenField ID="hfIsManager" runat="server" Value="N" />
